package com.e3.basdoc.measure.client;

import java.util.List;

import com.e3.basdoc.measure.model.MeasureUnitModel;
import com.e3.basdoc.measure.model.MeasureUnitQC;
import com.e3.web.core.client.RPCServiceHelper;
import com.e3.web.core.client.WebException;
import com.google.gwt.core.client.GWT;
import com.google.gwt.user.client.rpc.RemoteService;

public interface MeasureUnitRPCService extends RemoteService {
	public static class Util {

		private static MeasureUnitRPCServiceAsync instance;

		public static MeasureUnitRPCServiceAsync getInstance() {
			instance = (MeasureUnitRPCServiceAsync) RPCServiceHelper.getService(MeasureUnitRPCService.class.getName());
			if (instance == null) {
				instance = GWT.create(MeasureUnitRPCService.class);
				RPCServiceHelper.registerServiceEntryPoint(instance);
			}
			return instance;
		}

	}

	public MeasureUnitModel newMeasureUnit(MeasureUnitModel model) throws WebException;
	
	public MeasureUnitModel modifyMeasureUnit(MeasureUnitModel model) throws WebException;
	
	public List<MeasureUnitModel> getMeasureUnitByCondition(MeasureUnitQC currencyQC) throws WebException;
	
	public void deleteMeasureUnits(List<MeasureUnitModel> banks) throws WebException;

}
